home *** CD-ROM | disk | FTP | other *** search
/ The Latest & Greatest Top 201 Games / The Latest and Greatest Top 201 Games (Maple Media)(1994).iso / mardemo / install.bat < prev    next >
DOS Batch File  |  1991-07-26  |  3KB  |  94 lines

  1. ECHO off
  2. CLS
  3. IF %1x == x GOTO NoParms
  4. IF %1 == a: GOTO OkSource
  5. IF %1 == b: GOTO OkSource
  6. IF %1 == A: GOTO OkSource
  7. IF %1 == B: GOTO OkSource
  8. IF %1 == c: GOTO NoSource
  9. IF %1 == d: GOTO NoSource
  10. IF %1 == C: GOTO NoSource
  11. IF %1 == D: GOTO NoSource
  12. IF %1 == e: GOTO NoSource
  13. IF %1 == f: GOTO NoSource
  14. IF %1 == E: GOTO NoSource
  15. IF %1 == F: GOTO NoSource
  16. ECHO Only A: and B: are allowed as source drives...
  17. ECHO Only C: D: E: and F: are allowed as destination drives...
  18. GOTO NoParms
  19.  
  20. :OkSource
  21. IF %3 == c: GOTO OkDest
  22. IF %3 == d: GOTO OkDest
  23. IF %3 == C: GOTO OkDest
  24. IF %3 == D: GOTO OkDest
  25. IF %3 == e: GOTO OkDest
  26. IF %3 == f: GOTO OkDest
  27. IF %3 == E: GOTO OkDest
  28. IF %3 == F: GOTO OkDest
  29. ECHO Only C: D: E: and F: are allowed as destination drives...
  30. GOTO NoParms
  31.  
  32. :OkDest
  33. %1
  34. CD\
  35. IF NOT EXIST MMDEMO.EXE GOTO WrongSrc
  36. IF NOT EXIST %1\MMDEMO\*.* MD %3\MMDEMO
  37. COPY %1\*.* %3\MMDEMO
  38. IF NOT EXIST %3\MMDEMO\MMDEMO.EXE GOTO NoInstal
  39. %3
  40. GOTO GoodInst
  41.  
  42. :WrongSrc
  43. ECHO Place the MARTIAN MEMORANDUM demo disk into drive
  44. PAUSE
  45. GOTO OkDest
  46.  
  47. :NoSource
  48. A:
  49. CD\
  50. IF NOT EXIST MMDEMO.EXE GOTO WrongSrc
  51. IF NOT EXIST %1\MMDEMO\. MD %1\MMDEMO
  52. COPY A:\*.* %1\MMDEMO
  53. IF NOT EXIST %1\MMDEMO\MMDEMO.EXE GOTO NoInstal
  54. %1
  55. GOTO GoodInst
  56.  
  57. :GoodInst
  58. CLS
  59. ECHO MARTIAN MEMORANDUM has been successfully installed.
  60. ECHO Type: MMDEMO to execute.
  61. CD \MMDEMO
  62. GOTO Done
  63.  
  64. :NoInstal
  65. ECHO There was an error during installation. Check to see that you have enough
  66. ECHO free space on your hard disk (you need at least 1.2 meg free) and that
  67. ECHO you are using INSTALL correctly.
  68. GOTO NoParms
  69.  
  70. GOTO done
  71. :NoParms
  72. ECHO ----------------------------------------------------------------------------
  73. ECHO INSTALL will create a directory named MMDEMO on your hard drive.
  74. ECHO The files from your copy of MARTIAN MEMORANDUM demo will be copied
  75. ECHO to the MMDEMO directory on your hard disk.
  76. ECHO Only hard drives C: D: E: or F: are allowed.
  77. ECHO ----------------------------------------------------------------------------
  78. ECHO You must supply the letter for your hard drive followed by a semi-colon
  79. ECHO For example, if you want to copy to drive C:
  80. ECHO type:
  81. ECHO              INSTALL C:
  82. ECHO ----------------------------------------------------------------------------
  83. ECHO You can also specify floppy drive A: or B: as the drive containing your
  84. ECHO MARTIAN MEMORANDUM demo disk. If you do not specify a drive, INSTALL will
  85. ECHO assume you are using drive A:. Only drive A: or B: are allowed.
  86. ECHO For example, if you want to install to hard disk D: from floppy drive B:
  87. ECHO type:
  88. ECHO              INSTALL B: TO D:
  89. ECHO *** You must type the 'TO' if you are using this method. ***
  90. ECHO ----------------------------------------------------------------------------
  91. GOTO Done
  92.  
  93. :Done
  94.